package org.geektimes.rest.demo;


import org.junit.Test;

import javax.ws.rs.client.Client;
import javax.ws.rs.client.ClientBuilder;
import javax.ws.rs.core.Response;

/**
 * @Author: jipeng
 * @Description:
 * @Date: Created in 2021/3/27 16:47
 */
public class RestClientDemo {


    @Test
    public void httpGetTest(){
        Client client = ClientBuilder.newClient();
        Response response = client
                .target("http://localhost:8080/test/get")
                .request()
                .get();

        String content = response.readEntity(String.class);
        System.out.println(content);

    }


    @Test
    public void httpPostTest(){



    }

}
